<div>
  <!--<a [routerLink]="['/addUser']">dffd</a>-->
  <button class="btn btn-outline-info col-xs-3 float-right mr-5" (click)="edit()">添加用户</button>
</div>
<table class="table table-bordered table-hover">
  <tr>
    <th>序号</th>
    <th>账号</th>
    <th>姓名</th>
    <th>电话</th>
    <th>性别</th>
    <th>角色</th>
    <th>邮箱</th>
    <th>所属部门</th>
    <th>添加时间</th>
    <th>操作</th>
  </tr>
  <tr *ngFor="let d of userList;let i = index">
    <td>{{i + 1}}</td>
    <td>{{d.account}}</td>
    <td>{{d.perName}}</td>
    <td>{{d.mobile}}</td>
    <td>{{d.sexCode}}</td>
    <td>{{d.role}}</td>
    <td>{{d.email}}</td>
    <td>{{d.department?d.department.name:''}}</td>
    <td>{{d.addDateTime|date:'yyyy-MM-dd hh:mm:ss'}}</td>
    <td>
      <button class="btn btn-outline-info btn-sm" title="编辑" (click)="edit(d.id)">
        编辑
      </button>
      <button type="button" class="btn btn-outline-danger btn-sm" title="删除">
        删除
      </button>
    </td>
  </tr>
</table>
